package org.zizi.modal;

import org.zizi.util.EqualUtil;

public class AbstractBean implements Bean
{
	private static final long serialVersionUID = 1L;

	public boolean equals(Object obj)
	{
		if (obj == null) return false;
		if (!(obj instanceof Bean)) return false;
		
		if ((obj instanceof IdBean) && (this instanceof IdBean))
		{
			return EqualUtil.equal(((IdBean)obj).getId(), ((IdBean)this).getId());
		}
		else
		{
			return super.equals(obj);
		}
	}
}
